﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Master.Master" AutoEventWireup="true" CodeBehind="wfrmDetalleReservaServicio.aspx.cs" Inherits="EvolSoftWeb.wfrmDetalleReservaServicio" %>

<%@ Register Assembly="DevExpress.Web.v11.2, Version=11.2.7.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxRoundPanel" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v11.2, Version=11.2.7.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxPanel" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v11.2, Version=11.2.7.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxTabControl" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v11.2, Version=11.2.7.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxClasses" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.ASPxEditors.v11.2, Version=11.2.7.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxEditors" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.ASPxGridView.v11.2, Version=11.2.7.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxGridView" TagPrefix="dx" %>
<%@ Register Assembly="DevExpress.Web.v11.2, Version=11.2.7.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxPopupControl" TagPrefix="dx" %>
<asp:Content ID="Content1" ContentPlaceHolderID="cphMain" runat="server">
 <style type="text/css">
        #principal
        {
            width: 900px;
            margin: 0 auto;
        }
        .tabs
        {
            width: 90%;
            margin: 0 auto;
        }
        .fieldset_datos
        {
            width: 100%;
        }
        .campos_vacios
        {
            width: 7em;
        }
        .labels
        {
            width: 125px;
        }
        .tabs fieldset
        {
            margin-top: 1.5em;
        }
        .tabs fieldset #fieldset_content
        {
            padding-left: 7em;
        }
        .tabs fieldset #fieldset_content1
        {
            padding-left: 7em;
        }
        .tabs fieldset .fieldset_filas
        {
            padding: .5em 0;
        }
        .filas
        {
            padding: .5em 3em;
        }
        .tabs .titulo
        {
            width: 100%;
            text-align: center;
            font-size: 24px;
            font-weight: bold;
            margin-bottom: 1em;
            margin-top: .5em;
        }
        .pad
        {
            padding: 0.2cm 1cm 0.2cm 1cm;
            text-align: left;
        }
        
        .p
        {
            padding: 0.2cm 0.6cm 0.2cm 0.6cm;
            text-align: left;
        }
        .pad
        {
            padding: 0.2cm 0.6cm 0.2cm 0.6cm;
         font-weight: 700;
     }
     
       .ped
        {
            padding: 0.2cm 0.2cm 0.2cm 0.2cm;
         font-weight: 700;
     }
        </style>
    <script type="text/javascript">
        function cargarDescripciones() {
            btnAccion.DoClick();
        }
    </script>
    <script type="text/javascript">
        function soloDocumento(e) {
            key = e.keyCode || e.which;
            tecla = String.fromCharCode(key).toLowerCase();
            letras = "abcdefghijklmnopqrstuvwxyz0123456789";
            especiales = [8, 127];
            tecla_especial = false
            for (var i in especiales) {
                if (key == especiales[i]) {
                    tecla_especial = true;
                    break;
                }
            }

            if (letras.indexOf(tecla) == -1 && !tecla_especial) {
                return false;
            }
        }
    </script>
    <asp:UpdatePanel runat="server" ID="update1">
    <ContentTemplate>
    <div class="main-header" style="width: 100%">
        <div class="main-titulo">
            Registro Detalle Servicios por Reserva</div>
    </div>
        <dx:ASPxRoundPanel ID="ASPxRoundPanel1" runat="server" Width="200px" 
            HeaderText="">
            <PanelCollection>
                <dx:PanelContent runat="server" SupportsDisabledAttribute="True">
                      
    <div class="content-form">
    <fieldset>
    
    <table>
    
    
    <tr>
    <td>
        &nbsp;</td>
    <td>
        Detalle de los servicios de cliente por su Reservas </td>
    <td>
        &nbsp;</td>
    </tr></table>
    </fieldset>
<table>
    <tr>
    <td class="pad">
        Reserva</td>
   <td class="pad">
   
       <dx:ASPxTextBox ID="txtIdReserva" runat="server" Width="170px" 
           ClientEnabled="False">
       </dx:ASPxTextBox>
   
   </td>
   <td class="pad">
   
        <dx:ASPxButton ID="btnBuscarReserva" runat="server" Text="Buscar" Width="100px" 
            onclick="btnBuscarReserva_Click">
        </dx:ASPxButton>
   
   </td>
    </tr>
    <tr>
    <td class="pad">
        Cliente</td>
   <td class="pad">
   
       <dx:ASPxTextBox ID="txtcliente" runat="server" Width="170px" 
           ClientEnabled="False">
       </dx:ASPxTextBox>
   
   </td>
   <td class="pad">
   
        &nbsp;</td>
    </tr>
    <tr>
    <td class="pad">
        Fecha Alquiler</td>
   <td class="pad">
   
       <dx:ASPxTextBox ID="txtfechaAlquiler" runat="server" Width="170px" 
           ClientEnabled="False">
       </dx:ASPxTextBox>
   
   </td>
   <td class="pad">
   
        &nbsp;</td>
    </tr>
    <tr>
    <td class="pad">
        Habitacion</td>
   <td class="pad">
   
       <dx:ASPxTextBox ID="txtIdHabitacion" runat="server" Width="170px">
       </dx:ASPxTextBox>
   
   </td>
   <td class="pad">
   
       &nbsp;</td>
    </tr>
    <tr>
    <td class="pad">
    &nbsp;Servicio:</td>
   <td class="pad">
   
       <dx:ASPxTextBox ID="txtServicioId" runat="server" Width="170px" 
           ClientEnabled="False">
       </dx:ASPxTextBox>
   
   </td>
   <td class="pad">
   
        <dx:ASPxButton ID="btnBuscarServicio" runat="server" Text="Buscar" 
            Width="100px" onclick="btnBuscarServicio_Click">
        </dx:ASPxButton>
   
   </td>
    </tr>
       <tr>
    <td>
        &nbsp;</td>
 
    </tr>
    </table>

    <table>
    
    <tr>
      <td>
       <dx:ASPxGridView ID="grdServicio" runat="server" AutoGenerateColumns="False" 
              Width="500px">
           <Columns>
               <dx:GridViewDataTextColumn FieldName="idServicios" VisibleIndex="0" 
                   Caption="Cod Servicio">
               </dx:GridViewDataTextColumn>
               <dx:GridViewDataTextColumn FieldName="nombre" VisibleIndex="2" Caption="Nombre">
               </dx:GridViewDataTextColumn>
               <dx:GridViewDataTextColumn FieldName="detalle" VisibleIndex="3" 
                   Caption="Detalle">
               </dx:GridViewDataTextColumn>
               <dx:GridViewDataTextColumn FieldName="tarifa" VisibleIndex="4" Caption="Tarifa">
               </dx:GridViewDataTextColumn>
              
             
           </Columns>
           <SettingsPager Visible="False">
           </SettingsPager>
       </dx:ASPxGridView>
           </td>
    </tr>
        <tr>
            <td align="right" class="ped">
                <dx:ASPxButton ID="ASPxButton3" runat="server" OnClick="ASPxButton3_Click" 
                    Text="Salir" Width="100px">
                </dx:ASPxButton>
            </td>
        </tr>
        </table>

     

        <br />

    </div>
                </dx:PanelContent>
            </PanelCollection>
        </dx:ASPxRoundPanel>

  
        <br />
        <dx:ASPxPopupControl ID="popupOK" runat="server" AllowDragging="True" 
            ClientInstanceName="popupOK" CloseAction="CloseButton" EnableHotTrack="False" 
            HeaderText="Mensaje" PopupHorizontalAlign="WindowCenter" 
            PopupVerticalAlign="WindowCenter" ShowPageScrollbarWhenModal="True" 
            Width="300px">
            <ContentCollection>
                <dx:PopupControlContentControl runat="server" SupportsDisabledAttribute="True">
                    <table align="center">
                        <tr>
                            <td>
                            </td>
                            <td>
                                <dx:ASPxLabel ID="lblmsgOK" runat="server">
                                </dx:ASPxLabel>
                            </td>
                            <td>
                            </td>
                        </tr>
                        <tr>
                            <td colspan="3">
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td colspan="3">
                                <dx:ASPxButton ID="btnAceptarOK" runat="server" AutoPostBack="False" 
                                    Text="Aceptar">
                                    <ClientSideEvents Click="function(s, e) {
	popupOK.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                        </tr>
                    </table>
                </dx:PopupControlContentControl>
            </ContentCollection>
        </dx:ASPxPopupControl>
        <dx:ASPxPopupControl ID="popupConfirmacion" runat="server" AllowDragging="True" 
            ClientInstanceName="popupConfirmacion" CloseAction="CloseButton" 
            EnableHotTrack="False" HeaderText="Confirmar" 
            PopupHorizontalAlign="WindowCenter" PopupVerticalAlign="WindowCenter" 
            ShowPageScrollbarWhenModal="True" Width="300px">
            <ContentCollection>
                <dx:PopupControlContentControl runat="server" SupportsDisabledAttribute="True">
                    <table align="center" width="100%">
                        <tr>
                            <td align="center" colspan="2">
                                <dx:ASPxLabel ID="lblmsgConfirmar" runat="server">
                                </dx:ASPxLabel>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td>
                                <dx:ASPxButton ID="btnConfirmar" runat="server" Text="Aceptar">
                                    <ClientSideEvents Click="function(s, e) {
	popupConfirmacion.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                            <td>
                                <dx:ASPxButton ID="btnCancelar" runat="server" Text="Cancelar">
                                    <ClientSideEvents Click="function(s, e) {
		popupConfirmacion.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                        </tr>
                    </table>
                </dx:PopupControlContentControl>
            </ContentCollection>
        </dx:ASPxPopupControl>
        <dx:ASPxPopupControl ID="popupConfirmarCateg" runat="server" 
            AllowDragging="True" ClientInstanceName="popupConfirmarCateg" 
            CloseAction="CloseButton" EnableHotTrack="False" HeaderText="Confirmar" 
            PopupHorizontalAlign="WindowCenter" PopupVerticalAlign="WindowCenter" 
            ShowPageScrollbarWhenModal="True" Width="300px">
            <ContentCollection>
                <dx:PopupControlContentControl runat="server" SupportsDisabledAttribute="True">
                    <table align="center" width="100%">
                        <tr>
                            <td align="center" colspan="2">
                                <dx:ASPxLabel ID="lblmsgConfCateg" runat="server">
                                </dx:ASPxLabel>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td>
                                <dx:ASPxButton ID="btnConfirmarCat" runat="server" Text="Aceptar">
                                    <ClientSideEvents Click="function(s, e) {
popupConfirmarCateg.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                            <td>
                                <dx:ASPxButton ID="btnCancelar0" runat="server" Text="Cancelar">
                                    <ClientSideEvents Click="function(s, e) {
	popupConfirmarCateg.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                        </tr>
                    </table>
                </dx:PopupControlContentControl>
            </ContentCollection>
        </dx:ASPxPopupControl>
        <dx:ASPxPopupControl ID="popupConfirmarHabit" runat="server" 
            AllowDragging="True" ClientInstanceName="popupConfirmarHabit" 
            CloseAction="CloseButton" EnableHotTrack="False" HeaderText="Confirmar" 
            PopupHorizontalAlign="WindowCenter" PopupVerticalAlign="WindowCenter" 
            ShowPageScrollbarWhenModal="True" Width="300px">
            <ContentCollection>
                <dx:PopupControlContentControl runat="server" SupportsDisabledAttribute="True">
                    <table align="center" width="100%">
                        <tr>
                            <td align="center" colspan="2">
                                <dx:ASPxLabel ID="lblmsgConfirmarHabit" runat="server">
                                </dx:ASPxLabel>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td>
                                <dx:ASPxButton ID="btnConfirmarHabit" runat="server" Text="Aceptar">
                                    <ClientSideEvents Click="function(s, e) {
popupConfirmarHabit.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                            <td>
                                <dx:ASPxButton ID="btnCancelar1" runat="server" Text="Cancelar">
                                    <ClientSideEvents Click="function(s, e) {
		popupConfirmacion.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                        </tr>
                    </table>
                </dx:PopupControlContentControl>
            </ContentCollection>
        </dx:ASPxPopupControl>
        <dx:ASPxPopupControl ID="popupReserva" runat="server" AllowDragging="True" 
            ClientInstanceName="popupReserva" CloseAction="CloseButton" 
            EnableHotTrack="False" HeaderText="Reserva" Modal="True" 
            PopupHorizontalAlign="WindowCenter" PopupVerticalAlign="WindowCenter" 
            ShowPageScrollbarWhenModal="True" Width="600px">
            <ContentCollection>
                <dx:PopupControlContentControl runat="server" SupportsDisabledAttribute="True">
                    <table align="center" width="100%">
                        <tr>
                            <td align="center" class="ped" colspan="4">
                                Seleccione una reserva</td>
                        </tr>
                        <tr>
                            <td align="center" class="ped" colspan="2">
                                &nbsp;</td>
                            <td align="center" class="ped" colspan="2">
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td align="center" class="ped" colspan="4">
                                <dx:ASPxGridView ID="grdReservas" runat="server" AutoGenerateColumns="False" 
                                    EnableCallBacks="False" KeyFieldName="idReserva" 
                                    OnFocusedRowChanged="grdReservas_FocusedRowChanged" Width="100%">
                                    <Columns>
                                        <dx:GridViewDataTextColumn Caption="Cod Reserva" FieldName="idReserva" 
                                            ShowInCustomizationForm="True" VisibleIndex="0">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn Caption="Cod Cliente" FieldName="usuario" 
                                            ShowInCustomizationForm="True" VisibleIndex="1">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn Caption="Cod Habitación" FieldName="idHabitacion" 
                                            ShowInCustomizationForm="True" VisibleIndex="2">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn Caption="F. Reserva" FieldName="fec_reserva" 
                                            ShowInCustomizationForm="True" VisibleIndex="3">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn Caption="F. Alquiler" FieldName="fec_alquiler" 
                                            ShowInCustomizationForm="True" Visible="False" VisibleIndex="4">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn Caption="F. Salida" FieldName="fec_salida" 
                                            ShowInCustomizationForm="True" VisibleIndex="5">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn Caption="Cod Servicio" FieldName="idServicios" 
                                            ShowInCustomizationForm="True" VisibleIndex="6">
                                        </dx:GridViewDataTextColumn>
                                    </Columns>
                                    <SettingsBehavior AllowFocusedRow="True" AllowSort="False" 
                                        ProcessFocusedRowChangedOnServer="True" />
                                    <SettingsPager Visible="False">
                                    </SettingsPager>
                                </dx:ASPxGridView>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                &nbsp;</td>
                            <td colspan="2">
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td align="center" class="ped">
                                <dx:ASPxButton ID="btnAgregarReserva" runat="server" AutoPostBack="False" 
                                    OnClick="btnAgregarReserva_Click" Text="Aceptar">
                                    <ClientSideEvents Click="function(s, e) {
popupConfirmarHabit.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                            <td colspan="2">
                                &nbsp;</td>
                            <td align="center" class="ped">
                                <dx:ASPxButton ID="btnCancelar2" runat="server" AutoPostBack="False" 
                                    Text="Cancelar">
                                    <ClientSideEvents Click="function(s, e) {
		popupConfirmacion.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                        </tr>
                    </table>
                </dx:PopupControlContentControl>
            </ContentCollection>
        </dx:ASPxPopupControl>
        <dx:ASPxPopupControl ID="popupServicios" runat="server" AllowDragging="True" 
            ClientInstanceName="popupServicio" CloseAction="CloseButton" 
            EnableHotTrack="False" HeaderText="Servicios" Modal="True" 
            PopupHorizontalAlign="WindowCenter" PopupVerticalAlign="WindowCenter" 
            ShowPageScrollbarWhenModal="True" Width="600px">
            <ContentCollection>
                <dx:PopupControlContentControl runat="server" SupportsDisabledAttribute="True">
                    <table align="center" width="100%">
                        <tr>
                            <td align="center" class="ped" colspan="4">
                                Seleccione un Servicio para agregar a la reserva</td>
                        </tr>
                        <tr>
                            <td align="center" class="ped" colspan="2">
                                &nbsp;</td>
                            <td align="center" class="ped" colspan="2">
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td align="center" class="ped" colspan="4">
                                <dx:ASPxGridView ID="grdDetalleServicio" runat="server" 
                                    AutoGenerateColumns="False" EnableCallBacks="False" KeyFieldName="idServicios" 
                                    Width="100%">
                                    <Columns>
                                        <dx:GridViewDataTextColumn Caption="Cod Servicio" FieldName="idServicios" 
                                            ShowInCustomizationForm="True" VisibleIndex="0">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn Caption="Nombre" FieldName="nombre" 
                                            ShowInCustomizationForm="True" VisibleIndex="1">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn Caption="Detalle" FieldName="detalle" 
                                            ShowInCustomizationForm="True" VisibleIndex="2">
                                        </dx:GridViewDataTextColumn>
                                        <dx:GridViewDataTextColumn Caption="Tarifa" FieldName="tarifa" 
                                            ShowInCustomizationForm="True" VisibleIndex="3">
                                        </dx:GridViewDataTextColumn>
                                    </Columns>
                                    <SettingsBehavior AllowFocusedRow="True" />
                                    <SettingsPager PageSize="1000" Visible="False">
                                    </SettingsPager>
                                    <Settings ShowVerticalScrollBar="True" />
                                </dx:ASPxGridView>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                &nbsp;</td>
                            <td colspan="2">
                                &nbsp;</td>
                        </tr>
                        <tr>
                            <td align="center" class="ped">
                                <dx:ASPxButton ID="btnAgregarDetalleServicio" runat="server" 
                                    OnClick="btnAgregarDetalleServicio_Click" Text="Agregar">
                                </dx:ASPxButton>
                            </td>
                            <td colspan="2">
                                &nbsp;</td>
                            <td>
                                <dx:ASPxButton ID="btnCancelar3" runat="server" AutoPostBack="False" 
                                    Text="Cancelar">
                                    <ClientSideEvents Click="function(s, e) {
		popupConfirmacion.Hide();
}" />
                                </dx:ASPxButton>
                            </td>
                        </tr>
                    </table>
                </dx:PopupControlContentControl>
            </ContentCollection>
        </dx:ASPxPopupControl>

  
    </ContentTemplate>
    </asp:UpdatePanel>

    <br />
</asp:Content>
